package com.yc.healthy.mapper;

import com.yc.healthy.entity.Food;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author lyl
 * @since 2023-03-08
 */
public interface FoodMapper extends BaseMapper<Food> {

    @Select("select * from food where ftype = #{ftype}")
    List<Food> SelectBytype(@Param("ftype") String type);

    @Select("select * from food where fid = #{fid}")
    Food QueryById(int id);
}
